<!DOCTYPE html> 
 
<%@ taglib uri="http://www.opensymphony.com/sitemesh/decorator" prefix="decorator" %> 
<%@ taglib uri="http://java.sun.com/jsp/jstl/core" prefix="c" %> 

<c:set var="ctx" value="${pageContext.request.contextPath}"/> 
<%@ page contentType="text/html;charset=UTF-8" %> 

<html lang="en">
<head>
<meta http-equiv="content-type" content="text/html; charset=utf-8" />
<meta name="viewport" content="width=device-width, initial-scale=1.0" />

<!-- Stylesheet -->
<link rel="stylesheet" href="<c:url value="/resources/css/vms.css"> </c:url>" />
<link rel="stylesheet" href="<c:url value="/resources/bootstrap3/css/bootstrap.css"> </c:url>" />

<style type="text/css">
.mainbody {
	margin-top: 60px;
	min-height: 100%;
	height: auto;
}
</style>

<script src="<c:url value="/resources/js/jquery/jquery-1.8.1.js"> </c:url>"></script>
<script src="<c:url value="/resources/js/jquery/jquery-ui-1.8.23.js"> </c:url>"></script>

<script src="<c:url value="/resources/js/common.js"> </c:url>"></script>
<script src="<c:url value="/resources/bootstrap3/js/bootstrap.js"> </c:url>"></script>

</head>
<body>
<header>
	<div id="appHeader" class="appHeader">
		<div class="container">
		<div class="row">
			<div class="col-xs-4 col-sm-4 col-md-4">
				<div class="applogo">VMS</div>
				<div>Volunteers Management System</div>
			</div>
		</div>
		</div>
	</div>
</header>
	<div class="container mainbody">
	<div class="row">
	<div class="col-xs-6 col-xs-offset-3 col-sm-6 col-sm-offset-3 col-md-4 col-md-offset-4">
	
	<div class="panel panel-primary">
		<div class="panel-heading">
			<h3 class="panel-title">VMS Login</h3>
		</div>
		<div class="panel-body">
			<form class="form-signin" action="<c:url value="/j_spring_security_check"> </c:url>" method="post">
				
				<div class="input-group form-group">
				  <span class="input-group-addon"><span class="glyphicon glyphicon-user"></span></span>
				  <input type="text" class="form-control" placeholder="Username" name="j_username">
				</div>
				
				<div class="input-group form-group">
				  <span class="input-group-addon"><span class="glyphicon glyphicon-lock"></span></span>
				  <input type="password" class="form-control" placeholder="Password" name="j_password">
				</div>
				
				<button type="submit" class="btn btn-primary">Login <span class="glyphicon glyphicon-chevron-right"></span></button>
			</form>
		</div>
	</div>
	<c:if test="${not empty ERROR}">
		<div class="alert alert-danger">
			Login failure, caused by "${sessionScope["SPRING_SECURITY_LAST_EXCEPTION"].message}"
		</div>
	</c:if>
	<c:if test="${not empty LOGOUT}">
		<div class="alert alert-success">
				Successfully logged out.
		</div>
	</c:if>
	</div>
	</div>
	</div>
	
	
	<!-- Footer -->
	<footer>
	<div class="footer">
      <div class="container">
        <p class="text-muted">Volunteers Management System. Raj Vidya Kender. 2013.</p>
      </div>
    </div>
    </footer>
</body>
</html> 